#ifndef _ANALYZER_H_
#define _ANALYZER_H_

#include "interface.h"
#include "UdpClient.h"
#include "RtpPacket.h"
#include "ContinuityCounterController.h"
#include <map>

using namespace std;;

class Analyzer : public UdpClient
{

public:
	Interface * gui;
	map<int,ContinuityCounterController*>  ts_ccc;
	map<int,ContinuityCounterController*>::iterator ts_ccc_it;

	ContinuityCounterController* rtp_ccc;

	int last_rtp_timestamp;
	int last_packet_toa;

	float ujitter; //microsecond jitter
	int nbr_of_packet_loss;
	float packet_loss_rate; //error rate;

public:
	Analyzer();
	bool process (UdpDatagram * udp_d);

};

#endif
